package np.com.baralsujan.login.da;

import java.util.Map;

import np.com.baralsujan.login.domain.User;
import np.com.baralsujan.login.util.AuthenticationException;

import org.hibernate.SessionFactory;

public interface IUserDao {

	public abstract User saveUser(User user);

	public abstract User retrieveUserByUsername(String username);

	/**
	 * @return the sessionFactory
	 */
	public abstract SessionFactory getSessionFactory();

	/**
	 * @param sessionFactory the sessionFactory to set
	 */
	public abstract void setSessionFactory(SessionFactory sessionFactory);

	public abstract void updateUser(User user);

	public abstract boolean deleteUser(User user);

	public abstract User authenticateUser(Map<String, Object> criteria)
			throws AuthenticationException;

}